Page({
    onShow: function() {
        this.getHistory(), this.getpoints();
    },
    getpoints: function() {
        var t = this, s = wx.getStorageSync("points");
        t.setData({
            points: s
        });
    },
    getHistory: function() {
        var t = this;
        wx.getStorage({
            key: "points_history",
            success: function(s) {
                var i = JSON.parse(s.data);
                t.setData({
                    list: i
                });
            }
        });
    }
});